package com.spring.dao;

import com.spring.pojo.SysModule;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;
/**
 * @author Tang
 */
@Repository
public interface ModuleDao {
    @Select("select * from sys_module roder by sortNuMBER ASC")
    public List<SysModule> getAllModule();
    @Select("select distinct moduleCode from sys_role_module where roleCode"+"in (select roleCode from sys_user_role where userCode=#{userCode})")
    List<String> getmoduleCodes(@Param("userCode") String userCode);

}
